﻿using System;
using System.Net;
using System.Windows;
#if (WINRT)
using Windows.UI.Xaml;
using Windows.UI.Xaml.Markup;
#else
using System.Windows.Markup;
#endif

namespace nRoute.Components
{
#if (WINRT)
    [ContentProperty(Name = "ChildMenu")]
#else
    [ContentProperty("ChildMenu")]
#endif
    public abstract class MenuCommandBase
        : VisualCommandBase
    {
        public static readonly DependencyProperty ChildMenuProperty = DependencyProperty.Register("ChildMenu", typeof(MenuCommandCollection),
            typeof(MenuCommandBase), new PropertyMetadata(Utilities.Compatability.DP_UNSET_VALUE));

        public MenuCommandBase()
        {
            this.ChildMenu = new MenuCommandCollection();
        }

        public MenuCommandCollection ChildMenu
        {
            get { return (MenuCommandCollection)GetValue(ChildMenuProperty); }
            set { SetValue(ChildMenuProperty, value); }
        }
    }
}
